package cn.wolfcode.crm.mapper;

import cn.wolfcode.crm.domain.Customer;
import cn.wolfcode.crm.domain.CustomerTransfer;
import cn.wolfcode.crm.domain.Employee;
import cn.wolfcode.crm.qo.CustomerQueryObject;
import cn.wolfcode.crm.qo.QueryObject;
import org.apache.ibatis.annotations.Param;

import java.util.List;

public interface CustomerMapper {
    int deleteByPrimaryKey(Long id);

    int insert(Customer record);

    Customer selectByPrimaryKey(Long id);

    List<Customer> selectAll();

    int updateByPrimaryKey(Customer record);

    List<Customer> selectForList(CustomerQueryObject qo);

    void updateByNewSeller(@Param("newSeller") Employee newSeller, @Param("customer") Customer customer);

    void updateStatus(@Param("status") Integer status, @Param("id") Long id);

    void updateByAbsorb(CustomerTransfer customerTransfer);

}